@extends('layouts.admin')
@push('morecss')
    <link href="/new/vendor/AdminInspinia/css/plugins/awesome-bootstrap-checkbox/awesome-bootstrap-checkbox.css"
          rel="stylesheet">
@endpush

@push('morescript')
    <!--webuploader上传组件JS-->
    <script type="text/javascript" src="/new/vendor/webuploader/webuploader.js"></script>
    <script type="application/javascript">
        let page_params = {
            @can('admin.wxcard.index')
            url_list: '{{ route('admin.wxcard.index') }}',
            @endcan
                    @can('admin.wxcard.create')
            url_add: '{{ route('admin.wxcard.create') }}',
            @endcan
                    @can('admin.wxcard.update')
            url_edit: '{{ route('admin.wxcard.update') }}',
            @endcan
            data_card:@json($cardData),
            data_card_type:@json($cardTypeList),
            data_card_key_group:@json($cardKeyGroupList),
            data_code_type:@json($codeTypeList),
            data_color:@json($colorList),
            data_date_type:@json($dateTypeList),
        }
    </script>
    <!-- require page js -->
    <script src="/new{{ mix('js/admin/wxcard_form.js') }}"></script>
@endpush
@section('content')
    <div class="wrapper wrapper-content animated fadeInRight ecommerce">
        <div class="row">
            <div class="col-lg-12">
                <div class="ibox float-e-margins">
                    <div class="ibox-title">
                        <h5>卡券编辑</h5>
                        <div class="ibox-tools">
                            <a class="collapse-link">
                                <i class="fa fa-chevron-up"></i>
                            </a>
                            <a class="dropdown-toggle" data-toggle="dropdown" href="#">
                                <i class="fa fa-wrench"></i>
                            </a>
                            <ul class="dropdown-menu dropdown-user">
                                <li><a href="{{ route('admin.wxcard.index') }}">返回</a>
                                </li>
                            </ul>
                        </div>
                    </div>
                    <div class="ibox-content">
                        <div class="tabs-container">
                            <ul class="nav nav-tabs">
                                <li class="active">
                                    <a data-toggle="tab" href="#tab-10" aria-expanded="true"
                                       v-on:click="changeTab">基础信息</a>
                                </li>
                                <li class="">
                                    <a data-toggle="tab" href="#tab-11" aria-expanded="false"
                                       v-on:click="changeTab">入口设置</a>
                                </li>
                                <li class="">
                                    <a data-toggle="tab" href="#tab-12" aria-expanded="false"
                                       v-on:click="changeTab">权限设置</a>
                                </li>
                                <li class="">
                                    <a data-toggle="tab" href="#tab-13" aria-expanded="false"
                                       v-on:click="changeTab">CODE码设置</a>
                                </li>
                                <li class="">
                                    <a data-toggle="tab" href="#tab-20" aria-expanded="false"
                                       v-on:click="changeTab">高级信息</a>
                                </li>
                                <li class="">
                                    <a data-toggle="tab" href="#tab-30" aria-expanded="false"
                                       v-on:click="changeTab">扩展信息</a>
                                </li>
                            </ul>
                            <div class="tab-content ">
                                <div id="tab-10" class="tab-pane active">
                                    <div class="panel-body">
                                        <form method="get" class="form-horizontal">
                                            <div class="form-group">
                                                <label class="col-sm-2 control-label">卡券类型 <span
                                                            style="color: red;">*</span></label>
                                                <div class="col-sm-2">
                                                    <select class="form-control m-b" name="card_type"
                                                            v-model="cardData.base.card_type"
                                                            v-bind:disabled="cardData.base.card_id != ''">
                                                        <option value="">请选择卡券类型</option>
                                                        <option v-for="item in card_type_list" v-bind:value="item.type">
                                                            @{{ item.name }}
                                                        </option>
                                                    </select>
                                                </div>
                                            </div>
                                            <div class="form-group">
                                                <label class="col-sm-2 control-label">卡券名称 <span
                                                            style="color: red;">*</span></label>
                                                <div class="col-sm-4">
                                                    <input type="text" class="form-control"
                                                           v-model="cardData.base.title"
                                                           v-bind:disabled="cardData.base.card_id != ''">
                                                </div>
                                            </div>
                                            <div class="form-group">
                                                <label class="col-sm-2 control-label">卡券标识 <span
                                                            style="color: red;">*</span></label>
                                                <div class="col-sm-8">
                                                    <select class="form-control m-b" style="width: 200px;" name="card_key"
                                                            v-model="cardData.base.card_key">
                                                        <option value="">请选择卡券标识</option>
                                                        <option v-for="item in card_key_list" v-bind:value="item.type">
                                                            @{{ item.name }}
                                                        </option>
                                                    </select>
                                                    <span class="help-block m-b-none">选择该卡券标识用于后台开发对应的卡券业务，该值的配置由开发人员维护</span>
                                                </div>
                                            </div>
                                            <div class="form-group">
                                                <label class="col-sm-2 control-label">商户名字 <span
                                                            style="color: red;">*</span></label>
                                                <div class="col-sm-4">
                                                    <input type="text" class="form-control"
                                                           v-model="cardData.base.brand_name"
                                                           v-bind:disabled="cardData.base.card_id != ''">
                                                </div>
                                            </div>
                                            <div class="form-group">
                                                <label class="col-sm-2 control-label">卡券的商户LOGO <span
                                                            style="color: red;">*</span></label>
                                                <div class="col-sm-2">
                                                    <webuploader-single :view-url.sync="cardData.base.logo_url"
                                                                        ref="logoUrl"
                                                                        btn-text="选择LOGO"></webuploader-single>
                                                </div>
                                            </div>
                                            <div class="form-group">
                                                <label class="col-sm-2 control-label">码型 <span
                                                            style="color: red;">*</span></label>
                                                <div class="col-sm-8">
                                                    <select class="form-control m-b" style="width: 200px;"
                                                            name="code_type"
                                                            v-model="cardData.base.code_type">
                                                        <option value="">请选择码型</option>
                                                        <option v-for="item in code_type_list" v-bind:value="item.type">
                                                            @{{ item.name }}
                                                        </option>
                                                    </select>
                                                    <span class="help-block m-b-none">
                                                        二维码/一维码显示code:适用于扫码/输码核销<br>
                                                        二维码不显示code:仅适用于扫码核销<br>
                                                        仅code类型:仅适用于输码核销<br>
                                                        无code类型:仅适用于线上核销，开发者须自定义跳转链接跳转至H5页面，允许用户核销掉卡券，自定义cell的名称可以命名为“立即使用”<br>
                                                    </span>
                                                </div>
                                            </div>
                                            <div class="form-group">
                                                <label class="col-sm-2 control-label">券颜色 <span
                                                            style="color: red;">*</span></label>
                                                <div class="col-sm-10">
                                                    <div class="input-group m-b">
                                                        <color-selecter v-bind:color-list="color_list"
                                                                        :color-name.sync="cardData.base.color"></color-selecter>
                                                    </div>
                                                </div>
                                            </div>
                                            <div class="hr-line-dashed"></div>
                                            <div class="form-group">
                                                <label class="col-sm-2 control-label">卡券使用提醒 <span
                                                            style="color: red;">*</span></label>
                                                <div class="col-sm-4">
                                                    <input type="text" class="form-control"
                                                           v-model="cardData.base.notice">
                                                    <span class="help-block m-b-none">选择展示二维码时，会展示此文案</span>
                                                </div>
                                            </div>
                                            <div class="form-group">
                                                <label class="col-sm-2 control-label">卡券使用说明 <span
                                                            style="color: red;">*</span></label>
                                                <div class="col-sm-4">
                                                    <textarea v-model="cardData.base.description" class="form-control"
                                                              style="height: 200px;"></textarea>
                                                </div>
                                            </div>
                                            <div class="form-group">
                                                <label class="col-sm-2 control-label">客服电话</label>
                                                <div class="col-sm-4">
                                                    <input type="text" class="form-control"
                                                           v-model="cardData.base.service_phone">
                                                    <span class="help-block m-b-none">例如：400-880-2280</span>
                                                </div>
                                            </div>
                                        </form>
                                    </div>
                                </div>
                                <div id="tab-11" class="tab-pane">
                                    <div class="panel-body">
                                        <form method="get" class="form-horizontal">
                                            <div class="hr-line-dashed"></div>
                                            <div class="form-group">
                                                <label class="col-sm-2 control-label">卡券顶部居中的按钮设置</label>
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">按钮文字</label>
                                                    <div class="col-sm-6">
                                                        <input type="text" class="form-control"
                                                               v-model="cardData.base.center_info.center_title">
                                                        <span class="help-block m-b-none">卡券顶部居中的按钮，仅在卡券状 态正常(可以核销)时显示</span>
                                                    </div>
                                                </div>
                                                <label class="col-sm-2 control-label"></label>
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">按钮提示语</label>
                                                    <div class="col-sm-6">
                                                        <input type="text" class="form-control" maxlength="6"
                                                               v-model="cardData.base.center_info.center_sub_title">
                                                        <span class="help-block m-b-none">显示在入口下方的提示语 ，仅在卡券状态正常(可以核销)时显示</span>
                                                    </div>
                                                </div>
                                                <label class="col-sm-2 control-label"></label>
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">按钮URL</label>
                                                    <div class="col-sm-6">
                                                        <input type="text" class="form-control"
                                                               v-model="cardData.base.center_info.center_url">
                                                        <span class="help-block m-b-none">顶部居中的url ，仅在卡券状态正常(可以核销)时显示。</span>
                                                    </div>
                                                </div>
                                                <label class="col-sm-2 control-label"></label>
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">小程序原始ID</label>
                                                    <div class="col-sm-6">
                                                        <input type="text" class="form-control"
                                                               v-model="cardData.base.center_info.center_app_brand_user_name">
                                                        <span class="help-block m-b-none">卡券跳转的小程序的原始ID，并加上"@app"，仅可跳转该 公众号绑定的小程序 。</span>
                                                    </div>
                                                </div>
                                                <label class="col-sm-2 control-label"></label>
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">小程序path</label>
                                                    <div class="col-sm-6">
                                                        <input type="text" class="form-control"
                                                               v-model="cardData.base.center_info.center_app_brand_pass">
                                                        <span class="help-block m-b-none">卡券跳转的小程序的path</span>
                                                    </div>
                                                </div>
                                            </div>
                                            <div class="hr-line-dashed"></div>
                                            <div class="form-group">
                                                <label class="col-sm-2 control-label">自定义跳转外链的入口设置</label>
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">入口文字</label>
                                                    <div class="col-sm-6">
                                                        <input type="text" class="form-control"
                                                               v-model="cardData.base.custom_info.custom_url_name">
                                                        <span class="help-block m-b-none">自定义跳转外链的入口名字</span>
                                                    </div>
                                                </div>
                                                <label class="col-sm-2 control-label"></label>
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">入口右侧提示语</label>
                                                    <div class="col-sm-6">
                                                        <input type="text" class="form-control" maxlength="6"
                                                               v-model="cardData.base.custom_info.custom_url_sub_title">
                                                        <span class="help-block m-b-none">显示在入口右侧的提示语。</span>
                                                    </div>
                                                </div>
                                                <label class="col-sm-2 control-label"></label>
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">跳转URL</label>
                                                    <div class="col-sm-6">
                                                        <input type="text" class="form-control"
                                                               v-model="cardData.base.custom_info.custom_url">
                                                        <span class="help-block m-b-none">自定义跳转的URL</span>
                                                    </div>
                                                </div>
                                                <label class="col-sm-2 control-label"></label>
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">小程序原始ID</label>
                                                    <div class="col-sm-6">
                                                        <input type="text" class="form-control"
                                                               v-model="cardData.base.custom_info.custom_app_brand_user_name">
                                                        <span class="help-block m-b-none">卡券跳转的小程序的原始ID，并加上"@app"，仅可跳转该 公众号绑定的小程序 。</span>
                                                    </div>
                                                </div>
                                                <label class="col-sm-2 control-label"></label>
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">小程序path</label>
                                                    <div class="col-sm-6">
                                                        <input type="text" class="form-control"
                                                               v-model="cardData.base.custom_info.custom_app_brand_pass">
                                                        <span class="help-block m-b-none">卡券跳转的小程序的path</span>
                                                    </div>
                                                </div>
                                            </div>
                                            <div class="hr-line-dashed"></div>
                                            <div class="form-group">
                                                <label class="col-sm-2 control-label">营销场景的自定义入口设置</label>
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">入口文字</label>
                                                    <div class="col-sm-6">
                                                        <input type="text" class="form-control"
                                                               v-model="cardData.base.promotion_info.promotion_url_name">
                                                        <span class="help-block m-b-none">营销场景的自定义入口名称。</span>
                                                    </div>
                                                </div>
                                                <label class="col-sm-2 control-label"></label>
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">入口右侧提示语</label>
                                                    <div class="col-sm-6">
                                                        <input type="text" class="form-control" maxlength="6"
                                                               v-model="cardData.base.promotion_info.promotion_url_sub_title">
                                                        <span class="help-block m-b-none">显示在营销入口右侧的提示语</span>
                                                    </div>
                                                </div>
                                                <label class="col-sm-2 control-label"></label>
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">跳转URL</label>
                                                    <div class="col-sm-6">
                                                        <input type="text" class="form-control"
                                                               v-model="cardData.base.promotion_info.promotion_url">
                                                        <span class="help-block m-b-none">入口跳转外链的地址链接。</span>
                                                    </div>
                                                </div>
                                                <label class="col-sm-2 control-label"></label>
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">小程序原始ID</label>
                                                    <div class="col-sm-6">
                                                        <input type="text" class="form-control"
                                                               v-model="cardData.base.promotion_info.promotion_app_brand_user_name">
                                                        <span class="help-block m-b-none">卡券跳转的小程序的原始ID，并加上"@app"，仅可跳转该 公众号绑定的小程序 。</span>
                                                    </div>
                                                </div>
                                                <label class="col-sm-2 control-label"></label>
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">小程序path</label>
                                                    <div class="col-sm-6">
                                                        <input type="text" class="form-control"
                                                               v-model="cardData.base.promotion_info.promotion_app_brand_pass">
                                                        <span class="help-block m-b-none">卡券跳转的小程序的path</span>
                                                    </div>
                                                </div>
                                            </div>
                                        </form>
                                    </div>
                                </div>
                                <div id="tab-12" class="tab-pane">
                                    <div class="panel-body">
                                        <form method="get" class="form-horizontal">
                                            <div class="hr-line-dashed"></div>
                                            <div class="form-group">
                                                <label class="col-sm-2 control-label">卡券库存<span
                                                            style="color: red;">*</span></label>
                                                <div class="col-sm-4">
                                                    <input type="number" min="0" max="100000000" class="form-control"
                                                           v-model="cardData.base.sku.quantity"
                                                           v-bind:disabled="cardData.base.card_id != ''">
                                                    <span class="help-block m-b-none">卡券库存的数量，上限为100000000。</span>
                                                </div>
                                            </div>
                                            <div class="hr-line-dashed"></div>
                                            <div class="form-group">
                                                <label class="col-sm-2 control-label">有效期设置 <span
                                                            style="color: red;">*</span></label>
                                                <div class="col-sm-4">
                                                    <select class="form-control m-b" name="code_type"
                                                            v-model="cardData.base.date_info.type"
                                                            v-bind:disabled="cardData.base.card_id != ''">
                                                        <option v-for="item in date_type_list" v-bind:value="item.type">
                                                            @{{ item.name }}
                                                        </option>
                                                    </select>
                                                </div>
                                            </div>
                                            <div class="form-group"
                                                 v-show="cardData.base.date_info.type=='DATE_TYPE_FIX_TIME_RANGE'">
                                                <label class="col-sm-2 control-label">启用开始结束时间<span
                                                            style="color: red;">*</span></label>
                                                <div class="col-sm-8">
                                                    <div class="col-sm-6">
                                                        <vue-datepicker-local
                                                                v-model="cardData.base.date_info.begin_timestamp"
                                                                format="YYYY-MM-DD HH:mm:ss" clearable
                                                                placeholder="开始时间"></vue-datepicker-local>
                                                    </div>
                                                    <div class="col-sm-6">
                                                        <vue-datepicker-local
                                                                v-model="cardData.base.date_info.end_timestamp"
                                                                format="YYYY-MM-DD HH:mm:ss" clearable
                                                                placeholder="结束时间"></vue-datepicker-local>
                                                    </div>
                                                    <span class="help-block m-b-none"></span>
                                                </div>
                                            </div>
                                            <div class="form-group"
                                                 v-show="cardData.base.date_info.type=='DATE_TYPE_FIX_TERM'">
                                                <label class="col-sm-2 control-label">有效天数</label>
                                                <div class="col-sm-6">
                                                    <input type="number" min="1" class="form-control"
                                                           v-model="cardData.base.date_info.fixed_term"
                                                           v-bind:disabled="cardData.base.card_id != ''">
                                                    <span class="help-block m-b-none">表示自领取后多少天内有效，不支持填写0。</span>
                                                </div>
                                            </div>
                                            <div class="form-group"
                                                 v-show="cardData.base.date_info.type=='DATE_TYPE_FIX_TERM'">
                                                <label class="col-sm-2 control-label">开始生效天数</label>
                                                <div class="col-sm-6">
                                                    <input type="number" min="0" class="form-control"
                                                           v-model="cardData.base.date_info.fixed_begin_term"
                                                           v-bind:disabled="cardData.base.card_id != ''">
                                                    <span class="help-block m-b-none">表示自领取后多少天开始生效，领取后当天生效填写0。（单位为天）</span>
                                                </div>
                                            </div>
                                            <div class="form-group"
                                                 v-show="cardData.base.date_info.type=='DATE_TYPE_FIX_TERM'">
                                                <label class="col-sm-2 control-label">统一过期时间</label>
                                                <div class="col-sm-6">
                                                    <vue-datepicker-local
                                                            v-model="cardData.base.date_info.end_timestamp"
                                                            format="YYYY-MM-DD HH:mm:ss" clearable placeholder="结束时间"
                                                            v-bind:disabled="cardData.base.card_id != ''"></vue-datepicker-local>
                                                    <span class="help-block m-b-none">表示卡券统一过期时间 ， 建议设置为截止日期的23:59:59过期 。</span>
                                                </div>
                                            </div>
                                            <div class="hr-line-dashed"></div>
                                            <div class="form-group">
                                                <label class="col-sm-2 control-label">可领券数量</label>
                                                <div class="col-sm-4">
                                                    <input type="number" min="1" class="form-control"
                                                           v-model="cardData.base.get_limit">
                                                    <span class="help-block m-b-none">每人可领券的数量限制</span>
                                                </div>
                                            </div>
                                            <div class="form-group">
                                                <label class="col-sm-2 control-label">可核销数量</label>
                                                <div class="col-sm-4">
                                                    <input type="number" min="1" class="form-control"
                                                           v-model="cardData.base.use_limit"
                                                           v-bind:disabled="cardData.base.card_id != ''">
                                                    <span class="help-block m-b-none">每人可核销的数量限制</span>
                                                </div>
                                            </div>
                                            <div class="hr-line-dashed"></div>
                                            <div class="form-group"><label
                                                        class="col-sm-2 control-label">是否指定用户领取</label>
                                                <div class="col-sm-8">
                                                    <div class="checkbox checkbox-primary">
                                                        <input id="bind_openid" type="checkbox" value="1"
                                                               v-model="cardData.base.bind_openid"
                                                               v-bind:disabled="cardData.base.card_id != ''">
                                                        <label for="bind_openid">
                                                        </label>
                                                    </div>
                                                    <span class="help-block m-b-none"></span>
                                                </div>
                                            </div>
                                            <div class="form-group"><label
                                                        class="col-sm-2 control-label">是否支持全部门店</label>
                                                <div class="col-sm-8">
                                                    <div class="checkbox checkbox-primary">
                                                        <input id="use_all_locations" type="checkbox" value="1"
                                                               v-model="cardData.base.use_all_locations"
                                                               v-bind:disabled="cardData.base.card_id != ''">
                                                        <label for="use_all_locations">
                                                        </label>
                                                    </div>
                                                    <span class="help-block m-b-none"></span>
                                                </div>
                                            </div>
                                            <div class="form-group" v-show="!cardData.base.use_all_locations">
                                                <label class="col-sm-2 control-label">门店位置poiid</label>
                                                <div class="col-sm-8">
                                                    <input-tag :tags.sync="cardData.base.location_id_list"
                                                               placeholder="请输入门店位置poiid..."></input-tag>
                                                    <span class="help-block m-b-none">记得按回车键确认</span>
                                                </div>
                                            </div>
                                            <div class="hr-line-dashed"></div>
                                            <div class="form-group"><label class="col-sm-2 control-label">是否可分享</label>
                                                <div class="col-sm-8">
                                                    <div class="checkbox checkbox-primary">
                                                        <input id="can_share" type="checkbox" value="1"
                                                               v-model="cardData.base.can_share">
                                                        <label for="can_share">
                                                        </label>
                                                    </div>
                                                    <span class="help-block m-b-none">卡券领取页面是否可分享,与分享给朋友使用互斥，若创建朋友共享券此处应取消勾选</span>
                                                </div>
                                            </div>
                                            <div class="form-group"><label class="col-sm-2 control-label">是否可转赠</label>
                                                <div class="col-sm-8">
                                                    <div class="checkbox checkbox-primary">
                                                        <input id="can_give_friend" type="checkbox" value="1"
                                                               v-model="cardData.base.can_give_friend">
                                                        <label for="can_give_friend">
                                                        </label>
                                                    </div>
                                                    <span class="help-block m-b-none">卡券是否可转赠,与分享给朋友使用互斥，若创建朋友共享券此处应取消勾选</span>
                                                </div>
                                            </div>
                                            <div class="form-group"><label class="col-sm-2 control-label">是否支持分享给朋友使用</label>
                                                <div class="col-sm-8">
                                                    <div class="checkbox checkbox-primary">
                                                        <input id="share_friends" type="checkbox" value="1"
                                                               v-model="cardData.advance.share_friends">
                                                        <label for="share_friends">
                                                        </label>
                                                    </div>
                                                    <span class="help-block m-b-none"></span>
                                                </div>
                                            </div>
                                        </form>
                                    </div>
                                </div>
                                <div id="tab-13" class="tab-pane">
                                    <div class="panel-body">
                                        <form method="get" class="form-horizontal">
                                            <div class="form-group">
                                                <label class="col-sm-2 control-label">是否自定义Code码</label>
                                                <div class="col-sm-8">
                                                    <div class="checkbox checkbox-primary">
                                                        <input id="use_custom_code" type="checkbox" value="1"
                                                               v-model="cardData.base.use_custom_code"
                                                               v-bind:disabled="cardData.base.card_id != ''">
                                                        <label for="use_custom_code">
                                                        </label>
                                                    </div>
                                                    <span class="help-block m-b-none">
                                                        通常自有优惠码系统的开发者选择自定义Code码，并在卡券投放时带入Code码，详情见<a target="_blank"
                                                                                                     href="https://mp.weixin.qq.com/wiki?t=resource/res_main&id=mp1451025056">是否自定义Code码</a> 。
                                                    </span>
                                                </div>
                                            </div>
                                            <div class="form-group" v-show="cardData.base.use_custom_code">
                                                <label class="col-sm-2 control-label">获取Code码方式</label>
                                                <div class="col-sm-8">
                                                    <div class="radio radio-primary radio-inline">
                                                        <input type="radio" id="inlineRadio1" value=""
                                                               name="radioInline"
                                                               v-model="cardData.base.get_custom_code_mode"
                                                               v-bind:disabled="cardData.base.card_id != ''">
                                                        <label for="inlineRadio1"> 接口创建 </label>
                                                    </div>
                                                    <div class="radio radio-primary radio-inline">
                                                        <input type="radio" id="inlineRadio2"
                                                               value="GET_CUSTOM_CODE_MODE_DEPOSIT" name="radioInline"
                                                               v-model="cardData.base.get_custom_code_mode"
                                                               v-bind:disabled="cardData.base.card_id != ''">
                                                        <label for="inlineRadio2"> 导入code模式 </label>
                                                    </div>
                                                    <span class="help-block m-b-none"><b>自定义Code码方式</b>通常为商户在现有业务已有一套Code码体系,仅支持API创建，<b>导入code模式</b>商户须用自己的code码体系，且要通过微信渠道下发卡券 （如：二维码/群发／货架等）</span>
                                                    <span class="help-block m-b-none"><b>预存code模式卡券</b>，须导入超过库存数目的自定义code后方可投放，填入该字段后，卡券库存数量须为0,须导入code 后再增加库存</span>
                                                </div>
                                            </div>
                                        </form>
                                    </div>
                                </div>
                                <div id="tab-20" class="tab-pane">
                                    <div class="panel-body">
                                        <form method="get" class="form-horizontal">
                                            <div class="form-group">
                                                <label class="col-sm-2 control-label">使用条件</label>
                                                <div class="form-group">
                                                    <div class="col-sm-6">
                                                        <div class="radio radio-primary radio-inline">
                                                            <input type="radio" id="islimit1" value="1"
                                                                   name="radioInline"
                                                                   v-model="cardData.advance.use_condition.islimit"
                                                                   v-bind:disabled="cardData.base.card_id != ''">
                                                            <label for="islimit1"> 有限制 </label>
                                                        </div>
                                                        <div class="radio radio-primary radio-inline">
                                                            <input type="radio" id="islimit2" value="0"
                                                                   name="radioInline"
                                                                   v-model="cardData.advance.use_condition.islimit"
                                                                   v-bind:disabled="cardData.base.card_id != ''">
                                                            <label for="islimit2"> 无门槛 </label>
                                                        </div>
                                                    </div>
                                                </div>
                                                <label v-show="cardData.advance.use_condition.islimit==1"
                                                       class="col-sm-2 control-label"></label>
                                                <div v-show="cardData.advance.use_condition.islimit==1"
                                                     class="form-group">
                                                    <label class="col-sm-2 control-label">可用商品类目</label>
                                                    <div class="col-sm-6">
                                                        <input type="text" class="form-control"
                                                               v-model="cardData.advance.use_condition.accept_category"
                                                               v-bind:disabled="cardData.base.card_id != ''">
                                                        <span class="help-block m-b-none">指定可用的商品类目，仅用于代金券类型 ，填入后将在券面拼写适用于xxx</span>
                                                    </div>
                                                </div>
                                                <label v-show="cardData.advance.use_condition.islimit==1"
                                                       class="col-sm-2 control-label"></label>
                                                <div v-show="cardData.advance.use_condition.islimit==1"
                                                     class="form-group">
                                                    <label class="col-sm-2 control-label">不可用商品类目</label>
                                                    <div class="col-sm-6">
                                                        <input type="text" class="form-control"
                                                               v-model="cardData.advance.use_condition.reject_category"
                                                               v-bind:disabled="cardData.base.card_id != ''">
                                                        <span class="help-block m-b-none">指定不可用的商品类目，仅用于代金券类型 ，填入后将在券面拼写不适用于xxxx</span>
                                                    </div>
                                                </div>
                                                <label v-show="cardData.advance.use_condition.islimit==1"
                                                       class="col-sm-2 control-label"></label>
                                                <div v-show="cardData.advance.use_condition.islimit==1"
                                                     class="form-group">
                                                    <label class="col-sm-2 control-label">满减门槛金额</label>
                                                    <div class="col-sm-6">
                                                        <input type="number" min="0" class="form-control"
                                                               v-model="cardData.advance.use_condition.least_cost"
                                                               v-bind:disabled="cardData.base.card_id != ''">
                                                        <span class="help-block m-b-none">可用于兑换券和代金券 ，填入后将在全面拼写消费满xx元可用。</span>
                                                    </div>
                                                </div>
                                                <label v-show="cardData.advance.use_condition.islimit==1"
                                                       class="col-sm-2 control-label"></label>
                                                <div v-show="cardData.advance.use_condition.islimit==1"
                                                     class="form-group">
                                                    <label class="col-sm-2 control-label">可用类型门槛</label>
                                                    <div class="col-sm-6">
                                                        <input type="text" class="form-control"
                                                               v-model="cardData.advance.use_condition.object_use_for"
                                                               v-bind:disabled="cardData.base.card_id != ''">
                                                        <span class="help-block m-b-none">仅用于兑换 ，填入后自动拼写购买xxx可用</span>
                                                    </div>
                                                </div>
                                                <label v-show="cardData.advance.use_condition.islimit==1"
                                                       class="col-sm-2 control-label"></label>
                                                <div v-show="cardData.advance.use_condition.islimit==1"
                                                     class="form-group">
                                                    <label class="col-sm-2 control-label">不可以与其他类型共享</label>
                                                    <div class="col-sm-6">
                                                        <div class="checkbox checkbox-primary">
                                                            <input id="can_use_with_other_discount" type="checkbox"
                                                                   value="1"
                                                                   v-model="cardData.advance.use_condition.can_use_with_other_discount"
                                                                   v-bind:disabled="cardData.base.card_id != ''">
                                                            <label for="can_use_with_other_discount">
                                                            </label>
                                                        </div>
                                                        <span class="help-block m-b-none">未勾选时时系统将在使用须知里 拼写“不可与其他优惠共享”， 勾选时系统将在使用须知里 拼写“可与其他优惠共享”</span>
                                                    </div>
                                                </div>
                                            </div>
                                            <div class="hr-line-dashed"></div>
                                            <div class="form-group">
                                                <label class="col-sm-2 control-label">封面摘要</label>
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">封面摘要简介</label>
                                                    <div class="col-sm-6">
                                                        <textarea v-model="cardData.advance.abstract.abstract"
                                                                  v-bind:disabled="cardData.base.card_id != ''"
                                                                  class="form-control"
                                                                  style="height: 200px;"></textarea>
                                                    </div>
                                                </div>
                                                <label class="col-sm-2 control-label"></label>
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">封面图片列表</label>
                                                    <div class="col-sm-2">
                                                        <webuploader-single
                                                                :view-url.sync="cardData.advance.abstract.icon_url_list[0]"
                                                                v-bind:disabled="cardData.base.card_id != ''"
                                                                ref="uploadIconUrlList"
                                                                btn-text="选择封面"></webuploader-single>
                                                        <span class="help-block m-b-none">建议图片尺寸像素850*350</span>
                                                    </div>
                                                </div>
                                            </div>
                                            <div class="hr-line-dashed"></div>
                                            <div class="form-group">
                                                <label class="col-sm-2 control-label">图文列表</label>
                                                <div class="col-sm-10">
                                                    <webuploader-multiple
                                                            :image-list.sync="cardData.advance.text_image_list"
                                                            v-bind:disabled="cardData.base.card_id != ''"
                                                            btn-text="选择相册"></webuploader-multiple>
                                                    <span class="help-block m-b-none">显示在详情内页 ，优惠券券开发者须至少传入 一组图文列表</span>
                                                </div>
                                            </div>
                                            <div class="form-group">
                                                <label class="col-sm-2 control-label">商家服务类型</label>
                                                <div class="col-sm-10">
                                                    <div class="checkbox checkbox-primary checkbox-inline"
                                                         v-for="(service, index) in business_service_list">
                                                        <input type="checkbox" :id="'bizServiceDeliver' + index"
                                                               v-bind:value="service.type"
                                                               v-bind:disabled="cardData.base.card_id != ''"
                                                               v-model="cardData.advance.business_service">
                                                        <label :for="'bizServiceDeliver' + index"> @{{ service.name
                                                            }} </label>
                                                    </div>
                                                </div>
                                            </div>
                                            <div class="form-group">
                                                <label class="col-sm-2 control-label">可用时段</label>
                                                <div class="col-sm-10">
                                                    <div class="checkbox checkbox-primary checkbox-inline"
                                                         v-for="(week, index) in time_limit_weeks_list">
                                                        <input type="checkbox" :id="'timeLimit' + index"
                                                               v-bind:value="week"
                                                               v-bind:disabled="cardData.base.card_id != ''"
                                                               v-model="cardData.advance.time_limit[index].isopen">
                                                        <label :for="'timeLimit' + index"> @{{ week.name }} </label>
                                                    </div>
                                                </div>
                                                <label class="col-sm-2 control-label"></label>
                                                <div class="col-sm-10">
                                                    <table class="table">
                                                        <thead>
                                                        <tr>
                                                            <th>周</th>
                                                            <th>起始时间(小时)</th>
                                                            <th>起始时间(分钟)</th>
                                                            <th>结束时间(小时)</th>
                                                            <th>结束时间(分钟)</th>
                                                        </tr>
                                                        </thead>
                                                        <tbody>
                                                        <tr v-for="item in time_limit_weeks_list" v-if="item.isopen">
                                                            <td>@{{ item.name }}</td>
                                                            <td><input type="number" min="0" max="23"
                                                                       v-bind:disabled="cardData.base.card_id != ''"
                                                                       class="form-control" v-model="item.begin_hour">
                                                            </td>
                                                            <td><input type="number" min="0" max="59"
                                                                       v-bind:disabled="cardData.base.card_id != ''"
                                                                       class="form-control" v-model="item.begin_minute">
                                                            </td>
                                                            <td><input type="number" min="0" max="23"
                                                                       v-bind:disabled="cardData.base.card_id != ''"
                                                                       class="form-control" v-model="item.end_hour">
                                                            </td>
                                                            <td><input type="number" min="0" max="59"
                                                                       v-bind:disabled="cardData.base.card_id != ''"
                                                                       class="form-control" v-model="item.end_minute">
                                                            </td>
                                                        </tr>
                                                        </tbody>
                                                    </table>
                                                </div>
                                            </div>
                                        </form>
                                    </div>
                                </div>
                                <div id="tab-30" class="tab-pane">
                                    <div class="panel-body">
                                        <form method="get" class="form-horizontal">
                                            <!--会员卡扩展信息-->
                                            <div v-show="cardData.base.card_type == 'MEMBER_CARD'">
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">会员卡背景图</label>
                                                    <div class="col-sm-4">
                                                        <webuploader-single
                                                                :view-url.sync="cardData.member.background_pic_url"
                                                                ref="backgroundPicUrl"
                                                                btn-text="选择背景图"></webuploader-single>
                                                        <span class="help-block m-b-none">建议图片尺寸像素850*350</span>
                                                    </div>
                                                </div>
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">会员卡特权说明</label>
                                                    <div class="col-sm-6">
                                                        <textarea v-model="cardData.member.prerogative"
                                                                  class="form-control"
                                                                  style="height: 200px;"></textarea>
                                                        <span class="help-block m-b-none">限制1024汉字</span>
                                                    </div>
                                                </div>
                                                <div class="hr-line-dashed"></div>
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">是否显示积分 <span
                                                                style="color: red;">*</span></label>
                                                    <div class="form-group">
                                                        <label class="col-sm-2 control-label"></label>
                                                        <div class="col-sm-8">
                                                            <div class="checkbox checkbox-primary">
                                                                <input id="supply_bonus" type="checkbox" value="1"
                                                                       v-model="cardData.member.bonus.supply_bonus">
                                                                <label for="supply_bonus">
                                                                </label>
                                                            </div>
                                                            <span class="help-block m-b-none">若勾选，积分相关字段均为必填 若设置勾选则后续不可以被关闭</span>
                                                        </div>
                                                    </div>
                                                    <label class="col-sm-2 control-label"
                                                           v-show="cardData.member.bonus.supply_bonus"></label>
                                                    <div class="form-group" v-show="cardData.member.bonus.supply_bonus">
                                                        <label class="col-sm-2 control-label">查看积分详情外链</label>
                                                        <div class="col-sm-6">
                                                            <input type="text" class="form-control"
                                                                   v-model="cardData.member.bonus.bonus_url">
                                                            <span class="help-block m-b-none">仅适用于积分无法通过激活接口同步的情况下使用该字段。</span>
                                                        </div>
                                                    </div>
                                                    <label class="col-sm-2 control-label"
                                                           v-show="cardData.member.bonus.supply_bonus"></label>
                                                    <div class="form-group" v-show="cardData.member.bonus.supply_bonus">
                                                        <label class="col-sm-2 control-label">积分清零规则</label>
                                                        <div class="col-sm-6">
                                                            <textarea v-model="cardData.member.bonus.bonus_cleared"
                                                                      class="form-control"
                                                                      style="height: 200px;"></textarea>
                                                        </div>
                                                    </div>
                                                    <label class="col-sm-2 control-label"
                                                           v-show="cardData.member.bonus.supply_bonus"></label>
                                                    <div class="form-group" v-show="cardData.member.bonus.supply_bonus">
                                                        <label class="col-sm-2 control-label">积分规则</label>
                                                        <div class="col-sm-6">
                                                            <textarea v-model="cardData.member.bonus.bonus_rules"
                                                                      class="form-control"
                                                                      style="height: 200px;"></textarea>
                                                        </div>
                                                    </div>
                                                </div>
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">是否支持储值 <span
                                                                style="color: red;">*</span></label>
                                                    <div class="form-group">
                                                        <div class="col-sm-8">
                                                            <div class="checkbox checkbox-primary">
                                                                <input id="supply_balance" type="checkbox" value="1"
                                                                       v-model="cardData.member.balance.supply_balance">
                                                                <label for="supply_balance">
                                                                </label>
                                                            </div>
                                                            <span class="help-block m-b-none">若勾选，储值相关字段均为必填;若勾选则后续不可以被关闭。该字段须开通储值功能后方可使用</span>
                                                        </div>
                                                    </div>
                                                    <label class="col-sm-2 control-label"
                                                           v-show="cardData.member.balance.supply_balance"></label>
                                                    <div class="form-group"
                                                         v-show="cardData.member.balance.supply_balance">
                                                        <label class="col-sm-2 control-label">查看余额详情外链</label>
                                                        <div class="col-sm-6">
                                                            <input type="text" class="form-control"
                                                                   v-model="cardData.member.balance.balance_url">
                                                            <span class="help-block m-b-none">仅适用于余额无法通过激活接口同步的情况下使用该字段。</span>
                                                        </div>
                                                    </div>
                                                    <label class="col-sm-2 control-label"
                                                           v-show="cardData.member.balance.supply_balance"></label>
                                                    <div class="form-group"
                                                         v-show="cardData.member.balance.supply_balance">
                                                        <label class="col-sm-2 control-label">储值说明</label>
                                                        <div class="col-sm-6">
                                                            <textarea v-model="cardData.member.balance.balance_rules"
                                                                      class="form-control"
                                                                      style="height: 200px;"></textarea>
                                                        </div>
                                                    </div>
                                                </div>
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">重要自定义会员信息一</label>
                                                    <div class="form-group">
                                                        <div class="col-sm-8">
                                                            <div class="checkbox checkbox-primary">
                                                                <input id="custom_field1_isopen" type="checkbox"
                                                                       value="1"
                                                                       v-model="cardData.member.custom_field1.isopen">
                                                                <label for="custom_field1_isopen">
                                                                </label>
                                                            </div>
                                                            <span class="help-block m-b-none"></span>
                                                        </div>
                                                    </div>
                                                    <label class="col-sm-2 control-label"></label>
                                                    <div class="form-group"
                                                         v-show="cardData.member.custom_field1.isopen">
                                                        <label class="col-sm-2 control-label">半自定义名称</label>
                                                        <div class="col-sm-6">
                                                            <select class="form-control m-b" name="card_type"
                                                                    v-model="cardData.member.custom_field1.name_type">
                                                                <option value="">自定义</option>
                                                                <option v-for="item in member_custom_field_name_type_list"
                                                                        v-bind:value="item.type"> @{{ item.name }}
                                                                </option>
                                                            </select>
                                                            <span class="help-block m-b-none">当开发者变更这类类目信息的value值时 可以选择触发系统模板消息通知用户</span>
                                                        </div>
                                                    </div>
                                                    <label class="col-sm-2 control-label"
                                                           v-show="!cardData.member.custom_field1.name_type && cardData.member.custom_field1.isopen"></label>
                                                    <div class="form-group"
                                                         v-show="!cardData.member.custom_field1.name_type && cardData.member.custom_field1.isopen">
                                                        <label class="col-sm-2 control-label">自定义名称</label>
                                                        <div class="col-sm-6">
                                                            <input type="text" class="form-control"
                                                                   v-model="cardData.member.custom_field1.name">
                                                            <span class="help-block m-b-none">当开发者变更这类类目信息的value值时，不会触发系统模板消息通知用户</span>
                                                        </div>
                                                    </div>
                                                    <label class="col-sm-2 control-label"
                                                           v-show="cardData.member.custom_field1.isopen"></label>
                                                    <div class="form-group"
                                                         v-show="cardData.member.custom_field1.isopen">
                                                        <label class="col-sm-2 control-label">点击跳转外链url</label>
                                                        <div class="col-sm-6">
                                                            <input type="text" class="form-control"
                                                                   v-model="cardData.member.custom_field1.url">
                                                        </div>
                                                    </div>
                                                </div>
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">重要自定义会员信息二</label>
                                                    <div class="form-group">
                                                        <div class="col-sm-8">
                                                            <div class="checkbox checkbox-primary">
                                                                <input id="custom_field2_isopen" type="checkbox"
                                                                       value="1"
                                                                       v-model="cardData.member.custom_field2.isopen">
                                                                <label for="custom_field2_isopen">
                                                                </label>
                                                            </div>
                                                            <span class="help-block m-b-none"></span>
                                                        </div>
                                                    </div>
                                                    <label class="col-sm-2 control-label"></label>
                                                    <div class="form-group"
                                                         v-show="cardData.member.custom_field2.isopen">
                                                        <label class="col-sm-2 control-label">半自定义名称</label>
                                                        <div class="col-sm-6">
                                                            <select class="form-control m-b" name="card_type"
                                                                    v-model="cardData.member.custom_field2.name_type">
                                                                <option value="">自定义</option>
                                                                <option v-for="item in member_custom_field_name_type_list"
                                                                        v-bind:value="item.type"> @{{ item.name }}
                                                                </option>
                                                            </select>
                                                            <span class="help-block m-b-none">当开发者变更这类类目信息的value值时 可以选择触发系统模板消息通知用户</span>
                                                        </div>
                                                    </div>
                                                    <label class="col-sm-2 control-label"
                                                           v-show="!cardData.member.custom_field2.name_type && cardData.member.custom_field2.isopen"></label>
                                                    <div class="form-group"
                                                         v-show="!cardData.member.custom_field2.name_type && cardData.member.custom_field2.isopen">
                                                        <label class="col-sm-2 control-label">自定义名称</label>
                                                        <div class="col-sm-6">
                                                            <input type="text" class="form-control"
                                                                   v-model="cardData.member.custom_field2.name">
                                                            <span class="help-block m-b-none">当开发者变更这类类目信息的value值时，不会触发系统模板消息通知用户</span>
                                                        </div>
                                                    </div>
                                                    <label class="col-sm-2 control-label"
                                                           v-show="cardData.member.custom_field2.isopen"></label>
                                                    <div class="form-group"
                                                         v-show="cardData.member.custom_field2.isopen">
                                                        <label class="col-sm-2 control-label">点击跳转外链url</label>
                                                        <div class="col-sm-6">
                                                            <input type="text" class="form-control"
                                                                   v-model="cardData.member.custom_field2.url">
                                                        </div>
                                                    </div>
                                                </div>
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">重要自定义会员信息三</label>
                                                    <div class="form-group">
                                                        <div class="col-sm-8">
                                                            <div class="checkbox checkbox-primary">
                                                                <input id="custom_field3_isopen" type="checkbox"
                                                                       value="1"
                                                                       v-model="cardData.member.custom_field3.isopen">
                                                                <label for="custom_field3_isopen">
                                                                </label>
                                                            </div>
                                                            <span class="help-block m-b-none"></span>
                                                        </div>
                                                    </div>
                                                    <label class="col-sm-2 control-label"></label>
                                                    <div class="form-group"
                                                         v-show="cardData.member.custom_field3.isopen">
                                                        <label class="col-sm-2 control-label">半自定义名称</label>
                                                        <div class="col-sm-6">
                                                            <select class="form-control m-b" name="card_type"
                                                                    v-model="cardData.member.custom_field3.name_type">
                                                                <option value="">自定义</option>
                                                                <option v-for="item in member_custom_field_name_type_list"
                                                                        v-bind:value="item.type"> @{{ item.name }}
                                                                </option>
                                                            </select>
                                                            <span class="help-block m-b-none">当开发者变更这类类目信息的value值时 可以选择触发系统模板消息通知用户</span>
                                                        </div>
                                                    </div>
                                                    <label class="col-sm-2 control-label"
                                                           v-show="!cardData.member.custom_field3.name_type && cardData.member.custom_field3.isopen"></label>
                                                    <div class="form-group"
                                                         v-show="!cardData.member.custom_field3.name_type && cardData.member.custom_field3.isopen">
                                                        <label class="col-sm-2 control-label">自定义名称</label>
                                                        <div class="col-sm-6">
                                                            <input type="text" class="form-control"
                                                                   v-model="cardData.member.custom_field3.name">
                                                            <span class="help-block m-b-none">当开发者变更这类类目信息的value值时，不会触发系统模板消息通知用户</span>
                                                        </div>
                                                    </div>
                                                    <label class="col-sm-2 control-label"
                                                           v-show="cardData.member.custom_field3.isopen"></label>
                                                    <div class="form-group"
                                                         v-show="cardData.member.custom_field3.isopen">
                                                        <label class="col-sm-2 control-label">点击跳转外链url</label>
                                                        <div class="col-sm-6">
                                                            <input type="text" class="form-control"
                                                                   v-model="cardData.member.custom_field3.url">
                                                        </div>
                                                    </div>
                                                </div>
                                                <div class="hr-line-dashed"></div>
                                                <div class="form-group"><label
                                                            class="col-sm-2 control-label">会员卡激活方式</label>
                                                    <div class="form-group">
                                                        <div class="col-sm-8">
                                                            <div class="checkbox checkbox-primary">
                                                                <select class="form-control m-b" name="card_type"
                                                                        v-model="cardData.member.activate.type">
                                                                    <option v-for="item in member_activate_type"
                                                                            v-bind:value="item.type"> @{{ item.name }}
                                                                    </option>
                                                                </select>
                                                            </div>
                                                            <span class="help-block m-b-none"
                                                                  v-show="cardData.member.activate.type == 'api'">
                                                                接口激活通常需要<b>开发者开发用户填写资料的网页</b>。通常有两种激活流程：<br>
                                                                用户必须在填写资料后才能领卡，领卡后开发者调用激活接口为用户激活会员卡；<br>
                                                                用户可以先领取会员卡，点击激活会员卡跳转至开发者设置的资料填写页面，填写完成后开发者调用激活接口为用户激活会员卡。
                                                            </span>
                                                            <span class="help-block m-b-none"
                                                                  v-show="cardData.member.activate.type == 'onekey'">
                                                                一键激活是微信提供的快速便捷的激活方案，用户领取后点击“激活会员卡”会跳转至官方的资料填写页面，微信会自动拉取该用户之前填写过的开卡信息，用户无需重复填写， 同时避免了手机号验证的过程，从而实现一键激活的目的，提高了开卡率。
                                                            </span>
                                                            <span class="help-block m-b-none"
                                                                  v-show="cardData.member.activate.type == 'auto'">
                                                                用户领取卡片之后，系统自动帮用户激活，积分、储值等自定义显示信息均为0，开发者可以通过更新会员信息接口更新用户会员数据。
                                                            </span>
                                                        </div>
                                                    </div>
                                                    <div v-show="cardData.member.activate.type == 'api'">
                                                        <label class="col-sm-2 control-label"> </label>
                                                        <div class="form-group">
                                                            <label class="col-sm-2 control-label">激活会员卡URL</label>
                                                            <div class="col-sm-6">
                                                                <input type="text" class="form-control"
                                                                       v-model="cardData.member.activate.activate_url">
                                                            </div>
                                                        </div>
                                                        <label class="col-sm-2 control-label"> </label>
                                                        <div class="form-group">
                                                            <label class="col-sm-2 control-label">激活会员卡小程序原始ID</label>
                                                            <div class="col-sm-6">
                                                                <input type="text" class="form-control"
                                                                       v-model="cardData.member.activate.activate_app_brand_user_name">
                                                                <span class="help-block m-b-none">加上"@app"，仅可跳转该公众号绑定的小程序</span>
                                                            </div>
                                                        </div>
                                                        <label class="col-sm-2 control-label"> </label>
                                                        <div class="form-group">
                                                            <label class="col-sm-2 control-label">激活会员卡小程序path</label>
                                                            <div class="col-sm-6">
                                                                <input type="text" class="form-control"
                                                                       v-model="cardData.member.activate.activate_app_brand_pass">
                                                            </div>
                                                        </div>
                                                    </div>
                                                    <div v-show="cardData.member.activate.type == 'onekey'">
                                                        <div class="form-group">
                                                            <label class="col-sm-2 control-label">一键激活方式</label>
                                                            <div class="form-group">
                                                                <div class="col-sm-6">
                                                                    <div class="radio radio-primary radio-inline">
                                                                        <input type="radio"
                                                                               id="wx_activate_after_submit1" value="0"
                                                                               name="radioInline"
                                                                               v-model="cardData.member.activate.wx_activate_after_submit">
                                                                        <label for="wx_activate_after_submit1">
                                                                            普通一键激活 </label>
                                                                    </div>
                                                                    <div class="radio radio-primary radio-inline">
                                                                        <input type="radio"
                                                                               id="wx_activate_after_submit2" value="1"
                                                                               name="radioInline"
                                                                               v-model="cardData.member.activate.wx_activate_after_submit">
                                                                        <label for="wx_activate_after_submit2">
                                                                            跳转型一键激活 </label>
                                                                    </div>
                                                                </div>
                                                            </div>
                                                        </div>
                                                        <div v-show="cardData.member.activate.wx_activate_after_submit == 1">
                                                            <div class="form-group">
                                                                <label class="col-sm-2 control-label">用户提交信息后跳转链接</label>
                                                                <div class="col-sm-6">
                                                                    <input type="text" class="form-control"
                                                                           v-model="cardData.member.activate.wx_activate_after_submit_url">
                                                                </div>
                                                            </div>
                                                        </div>
                                                        <div v-show="cardData.member.activate.wx_activate_after_submit == 0">
                                                            <div class="form-group">
                                                                <label class="col-sm-2 control-label">会员声明 </label>
                                                                <div class="form-group">
                                                                    <label class="col-sm-2 control-label">名称 </label>
                                                                    <div class="col-sm-6">
                                                                        <input type="text" class="form-control"
                                                                               v-model="cardData.member.service_statement.name">
                                                                    </div>
                                                                </div>
                                                                <label class="col-sm-2 control-label"></label>
                                                                <div class="form-group">
                                                                    <label class="col-sm-2 control-label">自定义url </label>
                                                                    <div class="col-sm-6">
                                                                        <input type="text" class="form-control"
                                                                               v-model="cardData.member.service_statement.url">
                                                                    </div>
                                                                </div>
                                                            </div>
                                                            <div class="form-group">
                                                                <label class="col-sm-2 control-label">绑定老会员链接 </label>
                                                                <div class="form-group">
                                                                    <label class="col-sm-2 control-label">链接名称 </label>
                                                                    <div class="col-sm-6">
                                                                        <input type="text" class="form-control"
                                                                               v-model="cardData.member.bind_old_card.name">
                                                                    </div>
                                                                </div>
                                                                <label class="col-sm-2 control-label"></label>
                                                                <div class="form-group">
                                                                    <label class="col-sm-2 control-label">自定义url </label>
                                                                    <div class="col-sm-6">
                                                                        <input type="text" class="form-control"
                                                                               v-model="cardData.member.bind_old_card.url">
                                                                    </div>
                                                                </div>
                                                            </div>
                                                        </div>
                                                        <div class="form-group">
                                                            <label class="col-sm-2 control-label">开卡字段 </label>
                                                            <div class="col-sm-10">
                                                                <table class="table">
                                                                    <thead>
                                                                    <tr>
                                                                        <th>字段名称</th>
                                                                        <th>启用</th>
                                                                        <th>必填</th>
                                                                        <th>操作</th>
                                                                    </tr>
                                                                    </thead>
                                                                    <tbody>
                                                                    <tr v-for="(item, index) in cardData.member.activate.field_list">
                                                                        <td>@{{ item.name }}</td>
                                                                        <td>
                                                                            <div class="checkbox checkbox-primary">
                                                                                <input type="checkbox"
                                                                                       :id="'member_field_isopen'+index"
                                                                                       v-bind:value="item.is_open"
                                                                                       v-model="cardData.member.activate.field_list[index].is_open">
                                                                                <label :for="'member_field_isopen' + index"> </label>
                                                                            </div>
                                                                        </td>
                                                                        <td>
                                                                            <div class="checkbox checkbox-primary">
                                                                                <input type="checkbox"
                                                                                       :id="'member_field_isrequired'+index"
                                                                                       v-bind:value="item.is_required"
                                                                                       v-model="cardData.member.activate.field_list[index].is_required">
                                                                                <label :for="'member_field_isrequired' + index"> </label>
                                                                            </div>
                                                                        </td>
                                                                        <td>
                                                                            <div v-show="!item.is_common">
                                                                                <button type="button"
                                                                                        v-on:click="memberFieldEdit(index)"
                                                                                        class="btn btn-default btn-sm">
                                                                                    <i class="fa fa-pencil"></i>
                                                                                    编辑
                                                                                </button>
                                                                                <button type="button"
                                                                                        v-on:click="memberFieldDel(index)"
                                                                                        class="btn btn-default btn-sm">
                                                                                    <i class="fa fa-trash"></i>
                                                                                    删除
                                                                                </button>
                                                                            </div>
                                                                        </td>
                                                                    </tr>
                                                                    <tr>
                                                                        <td colspan="4">
                                                                            <button type="button"
                                                                                    class="btn btn-primary"
                                                                                    v-on:click="memberFieldAdd()"><i
                                                                                        class="fa fa-plus"></i> 新增自定义字段
                                                                            </button>
                                                                        </td>
                                                                    </tr>
                                                                    </tbody>
                                                                </table>
                                                            </div>
                                                        </div>
                                                        <div class="form-group">
                                                            <label class="col-sm-2 control-label">用户激活后可否再次修改</label>
                                                            <div class="form-group">
                                                                <label class="col-sm-2 control-label">必填项 </label>
                                                                <div class="col-sm-6">
                                                                    <div class="checkbox checkbox-primary">
                                                                        <input id="required_form_can_modify"
                                                                               type="checkbox" value="1"
                                                                               v-model="cardData.member.activate.required_form_can_modify">
                                                                        <label for="required_form_can_modify">
                                                                        </label>
                                                                    </div>
                                                                </div>
                                                            </div>
                                                            <label class="col-sm-2 control-label"></label>
                                                            <div class="form-group">
                                                                <label class="col-sm-2 control-label">选填项 </label>
                                                                <div class="col-sm-6">
                                                                    <div class="checkbox checkbox-primary">
                                                                        <input id="required_form_can_modify"
                                                                               type="checkbox" value="1"
                                                                               v-model="cardData.member.activate.optional_form_can_modify">
                                                                        <label for="required_form_can_modify">
                                                                        </label>
                                                                    </div>
                                                                </div>
                                                            </div>
                                                        </div>
                                                    </div>
                                                </div>
                                                <div class="hr-line-dashed"></div>
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">其他自定义会员信息一</label>
                                                    <div class="form-group">
                                                        <div class="col-sm-8">
                                                            <div class="checkbox checkbox-primary">
                                                                <input id="custom_field3_isopen" type="checkbox" value="1"
                                                                       v-model="cardData.member.custom_cell1.isopen">
                                                                <label for="custom_cell1_isopen">
                                                                </label>
                                                            </div>
                                                            <span class="help-block m-b-none">会员卡激活后显示</span>
                                                        </div>
                                                    </div>
                                                    <label class="col-sm-2 control-label"
                                                           v-show="cardData.member.custom_cell1.isopen"></label>
                                                    <div class="form-group" v-show="cardData.member.custom_cell1.isopen">
                                                        <label class="col-sm-2 control-label">入口名称 <span
                                                                    style="color: red;">*</span></label>
                                                        <div class="col-sm-6">
                                                            <input type="text" class="form-control"
                                                                   v-model="cardData.member.custom_cell1.name">
                                                            <span class="help-block m-b-none"></span>
                                                        </div>
                                                    </div>
                                                    <label class="col-sm-2 control-label"
                                                           v-show="cardData.member.custom_cell1.isopen"></label>
                                                    <div class="form-group" v-show="cardData.member.custom_cell1.isopen">
                                                        <label class="col-sm-2 control-label">入口右侧提示语 <span
                                                                    style="color: red;">*</span></label>
                                                        <div class="col-sm-6">
                                                            <input type="text" class="form-control"
                                                                   v-model="cardData.member.custom_cell1.tips">
                                                            <span class="help-block m-b-none">6个汉字内</span>
                                                        </div>
                                                    </div>
                                                    <label class="col-sm-2 control-label"
                                                           v-show="cardData.member.custom_cell1.isopen"></label>
                                                    <div class="form-group" v-show="cardData.member.custom_cell1.isopen">
                                                        <label class="col-sm-2 control-label">入口跳转链接 <span
                                                                    style="color: red;">*</span></label>
                                                        <div class="col-sm-6">
                                                            <input type="text" class="form-control"
                                                                   v-model="cardData.member.custom_cell1.url">
                                                        </div>
                                                    </div>
                                                </div>
                                                <div class="form-group hidden">
                                                    <label class="col-sm-2 control-label">其他自定义会员信息二</label>
                                                    <div class="form-group">
                                                        <div class="col-sm-8">
                                                            <div class="checkbox checkbox-primary">
                                                                <input id="custom_field3_isopen" type="checkbox" value="1"
                                                                       v-model="cardData.member.custom_cell2.isopen">
                                                                <label for="custom_cell2_isopen">
                                                                </label>
                                                            </div>
                                                            <span class="help-block m-b-none">会员卡激活后显示</span>
                                                        </div>
                                                    </div>
                                                    <label class="col-sm-2 control-label"
                                                           v-show="cardData.member.custom_cell2.isopen"></label>
                                                    <div class="form-group" v-show="cardData.member.custom_cell2.isopen">
                                                        <label class="col-sm-2 control-label">入口名称 <span
                                                                    style="color: red;">*</span></label>
                                                        <div class="col-sm-6">
                                                            <input type="text" class="form-control"
                                                                   v-model="cardData.member.custom_cell2.name">
                                                            <span class="help-block m-b-none"></span>
                                                        </div>
                                                    </div>
                                                    <label class="col-sm-2 control-label"
                                                           v-show="cardData.member.custom_cell2.isopen"></label>
                                                    <div class="form-group" v-show="cardData.member.custom_cell2.isopen">
                                                        <label class="col-sm-2 control-label">入口右侧提示语 <span
                                                                    style="color: red;">*</span></label>
                                                        <div class="col-sm-6">
                                                            <input type="text" class="form-control"
                                                                   v-model="cardData.member.custom_cell2.tips">
                                                            <span class="help-block m-b-none">6个汉字内</span>
                                                        </div>
                                                    </div>
                                                    <label class="col-sm-2 control-label"
                                                           v-show="cardData.member.custom_cell2.isopen"></label>
                                                    <div class="form-group" v-show="cardData.member.custom_cell2.isopen">
                                                        <label class="col-sm-2 control-label">入口跳转链接 <span
                                                                    style="color: red;">*</span></label>
                                                        <div class="col-sm-6">
                                                            <input type="text" class="form-control"
                                                                   v-model="cardData.member.custom_cell2.url">
                                                        </div>
                                                    </div>
                                                </div>
                                                <div class="form-group hidden">
                                                    <label class="col-sm-2 control-label">其他自定义会员信息三</label>
                                                    <div class="form-group">
                                                        <div class="col-sm-8">
                                                            <div class="checkbox checkbox-primary">
                                                                <input id="custom_field3_isopen" type="checkbox" value="1"
                                                                       v-model="cardData.member.custom_cell3.isopen">
                                                                <label for="custom_cell3_isopen">
                                                                </label>
                                                            </div>
                                                            <span class="help-block m-b-none">会员卡激活后显示</span>
                                                        </div>
                                                    </div>
                                                    <label class="col-sm-2 control-label"
                                                           v-show="cardData.member.custom_cell3.isopen"></label>
                                                    <div class="form-group" v-show="cardData.member.custom_cell3.isopen">
                                                        <label class="col-sm-2 control-label">入口名称 <span
                                                                    style="color: red;">*</span></label>
                                                        <div class="col-sm-6">
                                                            <input type="text" class="form-control"
                                                                   v-model="cardData.member.custom_cell3.name">
                                                            <span class="help-block m-b-none"></span>
                                                        </div>
                                                    </div>
                                                    <label class="col-sm-2 control-label"
                                                           v-show="cardData.member.custom_cell3.isopen"></label>
                                                    <div class="form-group" v-show="cardData.member.custom_cell3.isopen">
                                                        <label class="col-sm-2 control-label">入口右侧提示语 <span
                                                                    style="color: red;">*</span></label>
                                                        <div class="col-sm-6">
                                                            <input type="text" class="form-control"
                                                                   v-model="cardData.member.custom_cell3.tips">
                                                            <span class="help-block m-b-none">6个汉字内</span>
                                                        </div>
                                                    </div>
                                                    <label class="col-sm-2 control-label"
                                                           v-show="cardData.member.custom_cell3.isopen"></label>
                                                    <div class="form-group" v-show="cardData.member.custom_cell3.isopen">
                                                        <label class="col-sm-2 control-label">入口跳转链接 <span
                                                                    style="color: red;">*</span></label>
                                                        <div class="col-sm-6">
                                                            <input type="text" class="form-control"
                                                                   v-model="cardData.member.custom_cell3.url">
                                                        </div>
                                                    </div>
                                                </div>
                                                <div class="hr-line-dashed"></div>
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">积分规则</label>
                                                    <div class="form-group">
                                                        <label class="col-sm-2 control-label">消费金额</label>
                                                        <div class="col-sm-6">
                                                            <input type="number" min="0" class="form-control"
                                                                   v-model="cardData.member.bonus_rule.cost_money_unit">
                                                            <span class="help-block m-b-none">以分为单位</span>
                                                        </div>
                                                    </div>
                                                    <label class="col-sm-2 control-label"></label>
                                                    <div class="form-group">
                                                        <label class="col-sm-2 control-label">增加积分</label>
                                                        <div class="col-sm-6">
                                                            <input type="number" min="0" class="form-control"
                                                                   v-model="cardData.member.bonus_rule.increase_bonus">
                                                            <span class="help-block m-b-none">对应增加的积分</span>
                                                        </div>
                                                    </div>
                                                    <label class="col-sm-2 control-label"></label>
                                                    <div class="form-group">
                                                        <label class="col-sm-2 control-label">单次积分上限</label>
                                                        <div class="col-sm-6">
                                                            <input type="number" min="0" class="form-control"
                                                                   v-model="cardData.member.bonus_rule.max_increase_bonus">
                                                            <span class="help-block m-b-none">用户单次可获取的积分上限</span>
                                                        </div>
                                                    </div>
                                                    <label class="col-sm-2 control-label"></label>
                                                    <div class="form-group">
                                                        <label class="col-sm-2 control-label">初始积分</label>
                                                        <div class="col-sm-6">
                                                            <input type="number" min="0" class="form-control"
                                                                   v-model="cardData.member.bonus_rule.init_increase_bonus">
                                                            <span class="help-block m-b-none"></span>
                                                        </div>
                                                    </div>
                                                    <label class="col-sm-2 control-label"></label>
                                                    <div class="form-group">
                                                        <label class="col-sm-2 control-label">积分抵扣设置</label>
                                                        <div class="col-sm-6">
                                                            <div class="input-group m-b">
                                                                <span class="input-group-addon">每使用</span>
                                                                <input type="number" min="0" class="form-control"
                                                                       v-model="cardData.member.bonus_rule.cost_bonus_unit">
                                                                <span class="input-group-addon">积分抵扣</span>
                                                                <input type="number" min="0" class="form-control"
                                                                       v-model="cardData.member.bonus_rule.reduce_money">
                                                                <span class="input-group-addon">分</span>
                                                            </div>
                                                            <span class="help-block m-b-none">每使用xx积分抵扣xx元，（这里以分为单位）</span>
                                                        </div>
                                                    </div>
                                                    <label class="col-sm-2 control-label"></label>
                                                    <div class="form-group">
                                                        <label class="col-sm-2 control-label">满减最低消费金额</label>
                                                        <div class="col-sm-6">
                                                            <input type="number" min="0" class="form-control"
                                                                   v-model="cardData.member.bonus_rule.least_money_to_use_bonus">
                                                            <span class="help-block m-b-none">抵扣条件，满xx元（这里以分为单位）可用</span>
                                                        </div>
                                                    </div>
                                                    <label class="col-sm-2 control-label"></label>
                                                    <div class="form-group">
                                                        <label class="col-sm-2 control-label">单笔使用积分上限</label>
                                                        <div class="col-sm-6">
                                                            <input type="number" min="0" class="form-control"
                                                                   v-model="cardData.member.bonus_rule.max_reduce_bonus">
                                                            <span class="help-block m-b-none">抵扣条件，单笔最多使用xx积分</span>
                                                        </div>
                                                    </div>
                                                </div>
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">折扣</label>
                                                    <div class="col-sm-6">
                                                        <input type="number" min="1" max="100" class="form-control"
                                                               v-model="cardData.member.discount">
                                                        <span class="help-block m-b-none">该会员卡享受的折扣优惠,填10就是九折。(总金额*折扣/100=实际支付金额)</span>
                                                    </div>
                                                </div>
                                            </div>
                                            <!--团购券扩展信息-->
                                            <div v-show="cardData.base.card_type == 'GROUPON'">
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">团购详情</label>
                                                    <div class="col-sm-6">
                                                        <textarea v-model="cardData.ext.deal_detail"
                                                                  class="form-control"
                                                                  style="height: 200px;"></textarea>
                                                        <span class="help-block m-b-none"></span>
                                                    </div>
                                                </div>
                                            </div>
                                            <!--代金券扩展信息-->
                                            <div v-show="cardData.base.card_type == 'CASH'">
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">起用金额</label>
                                                    <div class="col-sm-6">
                                                        <input type="number" min="0" class="form-control"
                                                               v-bind:disabled="cardData.base.card_id != ''"
                                                               v-model="cardData.ext.least_cost">
                                                        <span class="help-block m-b-none">单位为分,如果无起用门槛则填0</span>
                                                    </div>
                                                </div>
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">减免金额</label>
                                                    <div class="col-sm-6">
                                                        <input type="number" min="0" class="form-control"
                                                               v-bind:disabled="cardData.base.card_id != ''"
                                                               v-model="cardData.ext.reduce_cost">
                                                        <span class="help-block m-b-none">单位为分</span>
                                                    </div>
                                                </div>
                                            </div>
                                            <!--折扣券扩展信息-->
                                            <div v-show="cardData.base.card_type == 'DISCOUNT'">
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">打折额度</label>
                                                    <div class="col-sm-6">
                                                        <input type="number" min="0" class="form-control"
                                                               v-bind:disabled="cardData.base.card_id != ''"
                                                               v-model="cardData.ext.discount">
                                                        <span class="help-block m-b-none">百分比，填30就是七折</span>
                                                    </div>
                                                </div>
                                            </div>
                                            <!--兑换券扩展信息-->
                                            <div v-show="cardData.base.card_type == 'GIFT'">
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">兑换内容</label>
                                                    <div class="col-sm-6">
                                                        <textarea v-model="cardData.ext.gift"
                                                                  v-bind:disabled="cardData.base.card_id != ''"
                                                                  class="form-control"
                                                                  style="height: 200px;"></textarea>
                                                        <span class="help-block m-b-none"></span>
                                                    </div>
                                                </div>
                                            </div>
                                            <!--优惠券扩展信息-->
                                            <div v-show="cardData.base.card_type == 'GENERAL_COUPON'">
                                                <div class="form-group">
                                                    <label class="col-sm-2 control-label">优惠详情</label>
                                                    <div class="col-sm-6">
                                                        <textarea v-model="cardData.ext.default_detail"
                                                                  v-bind:disabled="cardData.base.card_id != ''"
                                                                  class="form-control"
                                                                  style="height: 200px;"></textarea>
                                                        <span class="help-block m-b-none"></span>
                                                    </div>
                                                </div>
                                            </div>
                                        </form>
                                    </div>
                                </div>
                            </div>
                            <div class="row">
                                <div class="col-sm-4 col-sm-offset-4" style="margin-top: 20px;">
                                    <div class="col-sm-6 col-sm-offset-2">
                                        <a class="btn btn-white" href="{{ route('admin.wxcard.index') }}"><i
                                                    class="fa fa-arrow-left"></i> 返回</a>
                                        <button class="btn btn-primary" v-on:click="save" type="button">保存
                                        </button>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>

    <!--会员卡字段编辑-->
    <div class="ibox-content" id="box-member-field" style="display: none">
        <form class="form-horizontal m-t" method="post" action="">
            <div class="form-group">
                <label class="col-sm-3 control-label">富文本类型：</label>
                <div class="input-group col-sm-7">
                    <select class="form-control m-b" name="card_type" v-model="member_field_cur_data.type">
                        <option v-for="item in member_field_custom_type_list" v-bind:value="item.type"> @{{ item.name }}
                        </option>
                    </select>
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">字段名：</label>
                <div class="input-group col-sm-7">
                    <input type="text" class="form-control" v-model="member_field_cur_data.name">
                </div>
            </div>
            <div class="form-group" v-show="member_field_cur_data.type != 'FORM_FIELD_TEXT'">
                <label class="col-sm-3 control-label">选择项：</label>
                <div class="input-group col-sm-7">
                    <input-tag :tags.sync="member_field_cur_data.values" placeholder="请输入预选值..."></input-tag>
                    <span class="help-block m-b-none">按回车键确认</span>
                </div>
            </div>
            <div class="form-group">
                <div class="col-sm-4 col-sm-offset-4">
                    <button class="btn btn-primary btn-sub" type="button" v-on:click="memberFieldSave">提交</button>
                </div>
            </div>
        </form>
    </div>
@endsection